import request from '@/utils/request'

// 查询心跳列表
export function listHeartbeat(query) {
  return request({
    url: '/ips/heartbeat/list',
    method: 'get',
    params: query
  })
}

// 查询心跳详细
export function getHeartbeat(id) {
  return request({
    url: '/ips/heartbeat/' + id,
    method: 'get'
  })
}

// 新增心跳
export function addHeartbeat(data) {
  return request({
    url: '/ips/heartbeat/save',
    method: 'post',
    data: data
  })
}

// 修改心跳
export function editHeartbeat(data) {
  return request({
    url: '/ips/heartbeat/update',
    method: 'put',
    data: data
  })
}

// 删除心跳
export function delHeartbeat(id) {
  return request({
    url: '/ips/heartbeat/remove/' + id,
    method: 'delete'
  })
}

// 导出心跳
export function exportHeartbeat(query) {
  return request({
    url: '/ips/heartbeat/export',
    method: 'get',
    params: query
  })
}
